<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>

    <script type="text/javascript">
        //1.定义json
        var j1={"name":"张三","age":18};
       // alert(j1.name+","+j1.age);
        //数组
        var j2={"names":["aa","bb","cc"]};
        alert(j2.names[1]);
        //json数组内容
        var j3={"users":[{"name":"张三1","age":18},{"name":"张三2","age":15},{"name":"张三3","age":13}]};
        alert(j3.users[2].name);

    </script>
</head>
<body>

</body>
</html>